Integrand size = 18, antiderivative size = 123 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=\frac {2 d \log \left (\cos \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{3 a^2 f^2}-\frac {d \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f^2}+\frac {(c+d x) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{3 a^2 f}+\frac {(c+d x) \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right ) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f} \]
[Out]
Time = 0.11 (sec) , antiderivative size = 123, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {3399, 4270, 4269, 3556} \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=\frac {(c+d x) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{3 a^2 f}+\frac {(c+d x) \tan \left (\frac {e}{2}+\frac {f x}{2}\right ) \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f}-\frac {d \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f^2}+\frac {2 d \log \left (\cos \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{3 a^2 f^2} \]
[In]
[Out]
Rule 3399
Rule 3556
Rule 4269
Rule 4270
Rubi steps \begin{align*} \text {integral}& = \frac {\int (c+d x) \csc ^4\left (\frac {e+\pi }{2}+\frac {f x}{2}\right ) \, dx}{4 a^2} \\ & = -\frac {d \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f^2}+\frac {(c+d x) \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right ) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f}+\frac {\int (c+d x) \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right ) \, dx}{6 a^2} \\ & = -\frac {d \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f^2}+\frac {(c+d x) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{3 a^2 f}+\frac {(c+d x) \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right ) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f}-\frac {d \int \tan \left (\frac {e}{2}+\frac {f x}{2}\right ) \, dx}{3 a^2 f} \\ & = \frac {2 d \log \left (\cos \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{3 a^2 f^2}-\frac {d \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f^2}+\frac {(c+d x) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{3 a^2 f}+\frac {(c+d x) \sec ^2\left (\frac {e}{2}+\frac {f x}{2}\right ) \tan \left (\frac {e}{2}+\frac {f x}{2}\right )}{6 a^2 f} \\ \end{align*}
Time = 1.13 (sec) , antiderivative size = 113, normalized size of antiderivative = 0.92 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=\frac {\cos \left (\frac {1}{2} (e+f x)\right ) \left (2 d \cos \left (\frac {3}{2} (e+f x)\right ) \log \left (\cos \left (\frac {1}{2} (e+f x)\right )\right )+2 d \cos \left (\frac {1}{2} (e+f x)\right ) \left (-1+3 \log \left (\cos \left (\frac {1}{2} (e+f x)\right )\right )\right )+f (c+d x) \left (3 \sin \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {3}{2} (e+f x)\right )\right )\right )}{3 a^2 f^2 (1+\cos (e+f x))^2} \]
[In]
[Out]
Time = 1.68 (sec) , antiderivative size = 74, normalized size of antiderivative = 0.60
method | result | size |
parallelrisch | \(\frac {-2 d \ln \left (\sec ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )+\tan \left (\frac {f x}{2}+\frac {e}{2}\right ) \left (f \left (d x +c \right ) \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )-d \tan \left (\frac {f x}{2}+\frac {e}{2}\right )+3 \left (d x +c \right ) f \right )}{6 a^{2} f^{2}}\) | \(74\) |
default | \(\frac {\frac {c \left (\frac {\left (\tan ^{3}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{6}+\frac {\tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{2}\right )}{f}-\frac {d \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{6 f^{2}}+\frac {d x \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{2 f}+\frac {d x \left (\tan ^{3}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{6 f}-\frac {d \ln \left (1+\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{3 f^{2}}}{a^{2}}\) | \(109\) |
norman | \(\frac {\frac {c \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{2 a f}+\frac {c \left (\tan ^{3}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{6 a f}-\frac {d \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{6 a \,f^{2}}+\frac {d x \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{2 a f}+\frac {d x \left (\tan ^{3}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{6 a f}}{a}-\frac {d \ln \left (1+\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{3 a^{2} f^{2}}\) | \(128\) |
risch | \(-\frac {2 i d x}{3 a^{2} f}-\frac {2 i d e}{3 a^{2} f^{2}}-\frac {2 \left (-3 i d f x \,{\mathrm e}^{i \left (f x +e \right )}-3 i c f \,{\mathrm e}^{i \left (f x +e \right )}-i d f x -i c f +{\mathrm e}^{2 i \left (f x +e \right )} d +d \,{\mathrm e}^{i \left (f x +e \right )}\right )}{3 f^{2} a^{2} \left ({\mathrm e}^{i \left (f x +e \right )}+1\right )^{3}}+\frac {2 d \ln \left ({\mathrm e}^{i \left (f x +e \right )}+1\right )}{3 a^{2} f^{2}}\) | \(129\) |
[In]
[Out]
none
Time = 0.28 (sec) , antiderivative size = 118, normalized size of antiderivative = 0.96 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=-\frac {d \cos \left (f x + e\right ) - {\left (d \cos \left (f x + e\right )^{2} + 2 \, d \cos \left (f x + e\right ) + d\right )} \log \left (\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right ) - {\left (2 \, d f x + 2 \, c f + {\left (d f x + c f\right )} \cos \left (f x + e\right )\right )} \sin \left (f x + e\right ) + d}{3 \, {\left (a^{2} f^{2} \cos \left (f x + e\right )^{2} + 2 \, a^{2} f^{2} \cos \left (f x + e\right ) + a^{2} f^{2}\right )}} \]
[In]
[Out]
Time = 0.45 (sec) , antiderivative size = 146, normalized size of antiderivative = 1.19 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=\begin {cases} \frac {c \tan ^{3}{\left (\frac {e}{2} + \frac {f x}{2} \right )}}{6 a^{2} f} + \frac {c \tan {\left (\frac {e}{2} + \frac {f x}{2} \right )}}{2 a^{2} f} + \frac {d x \tan ^{3}{\left (\frac {e}{2} + \frac {f x}{2} \right )}}{6 a^{2} f} + \frac {d x \tan {\left (\frac {e}{2} + \frac {f x}{2} \right )}}{2 a^{2} f} - \frac {d \log {\left (\tan ^{2}{\left (\frac {e}{2} + \frac {f x}{2} \right )} + 1 \right )}}{3 a^{2} f^{2}} - \frac {d \tan ^{2}{\left (\frac {e}{2} + \frac {f x}{2} \right )}}{6 a^{2} f^{2}} & \text {for}\: f \neq 0 \\\frac {c x + \frac {d x^{2}}{2}}{\left (a \cos {\left (e \right )} + a\right )^{2}} & \text {otherwise} \end {cases} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 763 vs. \(2 (95) = 190\).
Time = 0.35 (sec) , antiderivative size = 763, normalized size of antiderivative = 6.20 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=-\frac {\frac {2 \, {\left (2 \, {\left (3 \, {\left (f x + e\right )} \sin \left (f x + e\right ) + \cos \left (2 \, f x + 2 \, e\right ) + \cos \left (f x + e\right )\right )} \cos \left (3 \, f x + 3 \, e\right ) + 2 \, {\left (9 \, {\left (f x + e\right )} \sin \left (f x + e\right ) + 6 \, \cos \left (f x + e\right ) + 1\right )} \cos \left (2 \, f x + 2 \, e\right ) + 6 \, \cos \left (2 \, f x + 2 \, e\right )^{2} + 6 \, \cos \left (f x + e\right )^{2} - {\left (2 \, {\left (3 \, \cos \left (2 \, f x + 2 \, e\right ) + 3 \, \cos \left (f x + e\right ) + 1\right )} \cos \left (3 \, f x + 3 \, e\right ) + \cos \left (3 \, f x + 3 \, e\right )^{2} + 6 \, {\left (3 \, \cos \left (f x + e\right ) + 1\right )} \cos \left (2 \, f x + 2 \, e\right ) + 9 \, \cos \left (2 \, f x + 2 \, e\right )^{2} + 9 \, \cos \left (f x + e\right )^{2} + 6 \, {\left (\sin \left (2 \, f x + 2 \, e\right ) + \sin \left (f x + e\right )\right )} \sin \left (3 \, f x + 3 \, e\right ) + \sin \left (3 \, f x + 3 \, e\right )^{2} + 9 \, \sin \left (2 \, f x + 2 \, e\right )^{2} + 18 \, \sin \left (2 \, f x + 2 \, e\right ) \sin \left (f x + e\right ) + 9 \, \sin \left (f x + e\right )^{2} + 6 \, \cos \left (f x + e\right ) + 1\right )} \log \left (\cos \left (f x + e\right )^{2} + \sin \left (f x + e\right )^{2} + 2 \, \cos \left (f x + e\right ) + 1\right ) - 2 \, {\left (f x + 3 \, {\left (f x + e\right )} \cos \left (f x + e\right ) + e - \sin \left (2 \, f x + 2 \, e\right ) - \sin \left (f x + e\right )\right )} \sin \left (3 \, f x + 3 \, e\right ) - 6 \, {\left (f x + 3 \, {\left (f x + e\right )} \cos \left (f x + e\right ) + e - 2 \, \sin \left (f x + e\right )\right )} \sin \left (2 \, f x + 2 \, e\right ) + 6 \, \sin \left (2 \, f x + 2 \, e\right )^{2} + 6 \, \sin \left (f x + e\right )^{2} + 2 \, \cos \left (f x + e\right )\right )} d}{a^{2} f \cos \left (3 \, f x + 3 \, e\right )^{2} + 9 \, a^{2} f \cos \left (2 \, f x + 2 \, e\right )^{2} + 9 \, a^{2} f \cos \left (f x + e\right )^{2} + a^{2} f \sin \left (3 \, f x + 3 \, e\right )^{2} + 9 \, a^{2} f \sin \left (2 \, f x + 2 \, e\right )^{2} + 18 \, a^{2} f \sin \left (2 \, f x + 2 \, e\right ) \sin \left (f x + e\right ) + 9 \, a^{2} f \sin \left (f x + e\right )^{2} + 6 \, a^{2} f \cos \left (f x + e\right ) + a^{2} f + 2 \, {\left (3 \, a^{2} f \cos \left (2 \, f x + 2 \, e\right ) + 3 \, a^{2} f \cos \left (f x + e\right ) + a^{2} f\right )} \cos \left (3 \, f x + 3 \, e\right ) + 6 \, {\left (3 \, a^{2} f \cos \left (f x + e\right ) + a^{2} f\right )} \cos \left (2 \, f x + 2 \, e\right ) + 6 \, {\left (a^{2} f \sin \left (2 \, f x + 2 \, e\right ) + a^{2} f \sin \left (f x + e\right )\right )} \sin \left (3 \, f x + 3 \, e\right )} - \frac {c {\left (\frac {3 \, \sin \left (f x + e\right )}{\cos \left (f x + e\right ) + 1} + \frac {\sin \left (f x + e\right )^{3}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{3}}\right )}}{a^{2}} + \frac {d e {\left (\frac {3 \, \sin \left (f x + e\right )}{\cos \left (f x + e\right ) + 1} + \frac {\sin \left (f x + e\right )^{3}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{3}}\right )}}{a^{2} f}}{6 \, f} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 661 vs. \(2 (95) = 190\).
Time = 0.49 (sec) , antiderivative size = 661, normalized size of antiderivative = 5.37 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=\text {Too large to display} \]
[In]
[Out]
Time = 18.84 (sec) , antiderivative size = 175, normalized size of antiderivative = 1.42 \[ \int \frac {c+d x}{(a+a \cos (e+f x))^2} \, dx=\frac {2\,d\,\ln \left ({\mathrm {e}}^{e\,1{}\mathrm {i}}\,{\mathrm {e}}^{f\,x\,1{}\mathrm {i}}+1\right )}{3\,a^2\,f^2}+\frac {\left (c\,f+d\,f\,x-d\,1{}\mathrm {i}\right )\,2{}\mathrm {i}}{3\,a^2\,f^2\,\left (2\,{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}+{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+1\right )}-\frac {d\,x\,2{}\mathrm {i}}{3\,a^2\,f}-\frac {2\,d}{3\,a^2\,f^2\,\left ({\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}+1\right )}+\frac {{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}\,\left (c+d\,x\right )\,4{}\mathrm {i}}{3\,a^2\,f\,\left (3\,{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}+3\,{\mathrm {e}}^{e\,2{}\mathrm {i}+f\,x\,2{}\mathrm {i}}+{\mathrm {e}}^{e\,3{}\mathrm {i}+f\,x\,3{}\mathrm {i}}+1\right )} \]
[In]
[Out]